<?php
/**
 * Template Name:create_faxing
 * 
 * @name 生成发型设计栏目静态页面
 * 
 * 
 */

$smarty = smarty_get_instance ();

//发型设计分类ID
$faxing_catid = 4;

//第一行第一列_幻灯片
$first_first = catid_article(118,$faxing_catid,3);

//第一行第二列__发型设计最新发表
$first_second = catid_article(117,$faxing_catid,1);

//右数第一列第一行 列表显示，前三条数据:热门点击：随机
$right_one_top = catid_article(119,$faxing_catid,8);

//右数第一列第二行 列表显示，前三条数据：编辑推荐以文章日期排序
$right_two_top = catid_article(119,$faxing_catid,1);

//右数第一列第三行 列表显示，前三条数据：最新：以id排序
$right_three_top = catid_article(119,$faxing_catid,4);

//右数第一列第一行 列表显示，下面十三条数据：以文章标题排序
$right_one_bottom = catid_article(120,$faxing_catid,3);

//右数第一列第二行 列表显示，下面十三条数据
$right_two_bottom = catid_article(120,$faxing_catid,3);

//右数第一列第三行 列表显示，下面十三条数据
$right_three_bottom = catid_article(120,$faxing_catid,1);

//左数第一列右边_自上而下都是相同html：下数第一行：此处对应位置为春夏秋冬发型设计，此处最后一个参数1代表发型设计下的春夏秋冬发型设计
$bottom_first_right = subcatid(152,$faxing_catid,8,1);

//左数第一列左边，下数第一行，末尾参数1代表：春夏秋冬发型设计
$bottom_first_left = subcatid(131,$faxing_catid,3,1);


//左数 第一列右边，下数第二行：此处对应：发型设计
$bottom_second_right = catid_article(152,$faxing_catid,8);

//左数第一列左边，下数第二行，发型设计
$bottom_second_left = catid_article(131,$faxing_catid,1);

//左数第一列右边，下数第三行、现对应位置女生发型设计；末尾参数2代表发型设计分类下的子目录女生发型设计
$bottom_third_right = subcatid(152,$faxing_catid,8,2);

//左数第一列左边，下数第三行，
$bottom_third_left = subcatid(131,$faxing_catid,1,2);

//左数第一列右边，下数第四行，流行发型设计，末尾参数3代表发型设计分类下子分类流行发型设计
$bottom_forth_right = subcatid(152,$faxing_catid,8,3);

//左数第一行左边，下数第四行，
$bottom_forth_left = subcatid(131,$faxing_catid,1,3);

$smarty->assign ( "first_first",$first_first);
$smarty->assign ( "first_second",$first_second);
$smarty->assign ( "right_one_top",$right_one_top);
$smarty->assign ( "right_two_top",$right_two_top);
$smarty->assign ( "right_three_top",$right_three_top);
$smarty->assign ( "right_one_bottom",$right_one_bottom);
$smarty->assign ( "right_two_bottom",$right_two_bottom);
$smarty->assign ( "right_three_bottom",$right_three_bottom);
$smarty->assign ( "bottom_first_right",$bottom_first_right);
$smarty->assign ( "bottom_second_right",$bottom_second_right);
$smarty->assign ( "bottom_third_right",$bottom_third_right);
$smarty->assign ( "bottom_forth_right",$bottom_forth_right);
$smarty->assign ( "bottom_first_left",$bottom_first_left);
$smarty->assign ( "bottom_second_left",$bottom_second_left);
$smarty->assign ( "bottom_third_left",$bottom_third_left);
$smarty->assign ( "bottom_forth_left",$bottom_forth_left);

$content = $smarty->fetch ( "faxingsheji.tpl" );
$fp = fopen ( "/home/admin/tueye/wordpress/wp-content/themes/tueye/faxingsheji.html", "w" );
fwrite ( $fp, $content );
fclose ( $fp );
?>